<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form"%>
<%@ taglib uri="/WEB-INF/html.tld" prefix="html"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>

<c:url var="url" value="add" />

		<div id='applicaton_form'>
			<div class="content-backgroud">
				<form:form id="applicationForm" modelAttribute="application"
					method="POST" action="${url}" name="applicationForm">
					<html:table attributes="class='inputTable' border='0' width='100%'">
						<tr>
							<td colspan="5" class="subSectionBottomBorder">
								<h4>
									<spring:message code="application.details">Application Details</spring:message>
									&nbsp;
								</h4>
							</td>
						</tr>
						<tr>
							<html:td>
								<label class="alpha-numeric required"><spring:message
										code='application.title' /></label>
							</html:td>
							<html:td>
								<label class="alpha-numeric optional"><spring:message
										code='application.type' /></label>
							</html:td>
							<html:td>&nbsp;</html:td>
							<html:td>&nbsp;</html:td>

						</tr>
						<tr>
							<html:td>
								<form:input path="application.title" name="application.title"
									css="alpha-numeric required"></form:input>
							</html:td>
							<html:td>
								<form:select path="application.type" name="application.type"
									css="required">
									<html:lov code='APP.TYP'>Application Type</html:lov>
								</form:select>
							</html:td>
							<html:td>&nbsp;</html:td>
							<html:td>&nbsp;</html:td>


						</tr>
					</html:table>
					<jsp:include page="asset_selection.jsp"></jsp:include>
<%--  					<jsp:include page="application_assets.jsp"></jsp:include> --%>
<%-- 					<jsp:include page="application_finance_selection.jsp"></jsp:include> --%>

				</form:form>
			</div>
		</div>
		

<script type="text/javascript">
<!--
	$(function() {
		$("#applicaton_form").window({
			footerbuttons : [ {
				name : 'Submit',
				onClick : submitForm,
				css : 'button-css'
			}, {
				name : 'Validate',
				onClick : validateForm,
				css : 'button-css'
			} ],

			headerButtons : [ {
				name : 'Submit',
				onClick : submitForm,
				css : 'button-css'
			}, {
				name : 'Validate',
				onClick : validateForm,
				css : 'button'
			} ]

		});

	})

	function submitForm() {
		alert("HEloo");
		document.applicationForm.submit();

	}
	function validateForm() {
		alert("Validate");
	}
//-->
</script>
